/*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */
package assisisw.smartcal.securitysubsystem;

import assisisw.smartcal.utilities.CommunicationException;
import java.io.Serializable;

/**
 *
 * @author Francesco
 */
public interface IMailVerifier extends Serializable 
{

    /**
     * @param mail
     * @return
     */
    public boolean isStaticallyOk ( String mail ) ;

    /**
     * @param mail
     * @return
     */
    public boolean exists ( String mail ) ;
    
    /**
     * @param eMail
     * @return
     * @throws CommunicationException
     */
    public String sendToken ( String eMail ) throws CommunicationException;

    /**
     * @param mail
     * @param token
     * @throws ActivationException
     */
    public void verifyTokenAndActivate ( String mail , String token ) 
            throws ActivationException;
    
}
